package labox.innovation.gameserver.network.clientpackets;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import labox.innovation.gameserver.ai.CtrlIntention;
import labox.innovation.gameserver.model.actor.instance.FuzePcInstance;

public final class AttackCancle extends L2GameClientPacket {
	
	private static final Logger _log=LoggerFactory.getLogger(AttackCancle.class.getName());

	private static final String _C__0A_ATTACKREQUEST = "[C] 0A AttackCancle";
	
	@Override
	public String getType() {
		// TODO Auto-generated method stub
		return _C__0A_ATTACKREQUEST;
	}

	@Override
	protected void readImpl() {
		// TODO Auto-generated method stub

	}

	@Override
	protected void runImpl() {
		// TODO Auto-generated method stub
		final FuzePcInstance activeChar = getClient().getActiveChar();
		
		if (activeChar == null)
			return;
		if(_log.isDebugEnabled())
			_log.debug("{} 取消了攻击状态",activeChar);
		activeChar.getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE);
	}

}
